home *** CD-ROM | disk | FTP | other *** search
- 10 rem **********************
- 12 rem * *
- 14 rem * cribbage solitaire *
- 15 rem * (commodore 64) *
- 16 rem * by *
- 17 rem * chris constantinou *
- 18 rem * february 1984 *
- 19 rem * *
- 20 rem **********************
- 70 lh=999:lc=999
- 80 poke53280,11:poke53281,15
- 90 def fnb(x)=int(x*10+.5)/10
- 95 poke54296,15:poke54277,68:poke54273,63:poke54272,75
- 110 dima(54),de(54),a$(11),rr$(13),v(13),r(13)
- 120 fori=1to13:readrr$(i):nexti
- 130 fori=1to13:readv(i):nexti
- 135 fori=1to13:readr(i):nexti
- 140 data a,2,3,4,5,6,7,8,9,10,j,q,k
- 150 data 1,2,3,4,5,6,7,8,9,10,10,10,10
- 155 data 1,2,3,4,5,6,7,8,9,10,11,12,13
- 160 print"[147] [146]"
- 161 print" cribbage solitaire [146]"
- 162 print" [146]"
- 164 print" do you wish to see"
- 165 printtab(16)"playing"
- 167 printtab(10)"[207][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][183][208]"
- 168 printtab(10)"[165]if yes,enter y or [167]"
- 170 printtab(10)"[165]hit return[146] to play[167]"
- 171 printtab(10)"[204][175][175][175][175][175][175][175][175][175][175][175][175][175][175][175][175][175][175][186]"
- 173 input"[145][145][145][145][145][145][145] instructions n[157][157][157]";a$
- 175 ifleft$(a$,1)="y"thengosub2600
- 178 print"[147] [146]"
- 179 print" cribbage solitaire [146]"
- 180 print" [146]"
- 181 print" shuffling the deck of cards"
- 182 printtab(13)"is in process"
- 185 fori=1to52:a(i)=i:nexti:i=1:cc=0:s=1:gt=0:hl=0:cl=0
- 190 forw=1to6:rem deal random cards to crib
- 200 cd=0:fori=itoi+1
- 220 gosub1005:rem deal random cards to crib
- 230 ifde(i)>39then270
- 240 ifde(i)>26then280
- 250 ifde(i)>13then290
- 260 r=de(i):sc$(cd)="[211]":goto295
- 270 r=de(i)-39:sc$(cd)="[193]":goto295
- 280 r=de(i)-26:sc$(cd)="[216]":goto295
- 290 r=de(i)-13:sc$(cd)="[218]"
- 295 rc$(cd)=rr$(r):rc(cd)=r(r):vc(cd)=v(r):nexti
- 395 rem *** deal hand ***
- 400 cd=0:fori=itoi+5
- 410 gosub1005:rem ** deal random cards **
- 420 ifde(i)>39then460
- 430 ifde(i)>26then470
- 440 ifde(i)>13then480
- 450 r=de(i):s$(cd)="[211]":goto485
- 460 r=de(i)-39:s$(cd)="[193]":goto485
- 470 r=de(i)-26:s$(cd)="[216]":goto485
- 480 r=de(i)-13:s$(cd)="[218]"
- 485 r$(cd)=rr$(r):rh(cd)=r(r):vh(cd)=v(r)
- 490 ifi=53then494
- 492 goto500
- 494 r$(6)=tr$(1):s$(6)=ts$(1):rh(6)=tr(1):vh(6)=tv(1):i=54
- 500 nexti
- 600 print"[147]":cc=0:d=6:gosub1045:rem ** sort hand of cards **
- 610 forl=1to6
- 620 r$=r$(l):s$=s$(l):r=rh(l)
- 630 c$="":ifr$="10"thenc$="[157]"
- 640 gosub1215:rem ** build graphics zone **
- 650 onrgosub1300,1350,1400,1450,1500,1550,1600,1650,1700,1750,1800,1850,1900
- 654 rem ** print card **
- 660 print"";:ifl<4thentb=cc*8+4:printtab(tb);l
- 661 ifs$="[211]"ors$="[218]"thenprint"";:goto663
- 662 print"[144]";
- 663 ifl<4then666
- 664 ifl=4thencc=0:print""
- 665 tb=cc*8+10
- 666 poke54276,129:forj=1to11:printtab(tb);a$(j):nextj:print"";:poke54276,128
- 667 ifl>3thenprinttab(tb);l
- 668 cc=cc+1:print"[145][145][145][145][145][145][145][145][145][145][145][145][145]":nextl:print""tab(30)"hand"w"[157][157][157]#[146]"
- 670 print"";
- 671 printtab(11)"select 2 cards for"
- 672 printtab(11)"crib."
- 673 printtab(11)"game points:[151]";gt
- 674 printtab(18)"[145][145][145]1st: [164] [157][157][157][157][157][157][157][157][157][157]";
- 675 poke198,0:wait198,1:getc1$:ifc1$="0"then63000
- 676 ifval(c1$)<1orval(c1$)>6then675
- 677 :
- 678 printc1$" 2nd: [164][157]";:c1=val(c1$)
- 679 getc2$:ifval(c2$)<1orval(c2$)>6orc2$=c1$then679
- 680 printc2$:c2=val(c2$)
- 683 print" [218] hit <return>[146] to score hand [218]";
- 685 geta$:ifa$=""then685
- 686 ifa$=chr$(20)ora$=chr$(157)then670
- 687 ifa$<>chr$(13)then685
- 690 cd=3:k=1:forj=1to6
- 695 ifj=c1orj=c2thenrc$(cd)=r$(j):sc$(cd)=s$(j):rc(cd)=rh(j):goto700
- 698 goto705
- 700 vc(cd)=vh(j):cd=cd+1:goto708
- 705 rs$(k)=r$(j):ss$(k)=s$(j):rs(k)=rh(j):vs(k)=vh(j):k=k+1
- 708 nextj
- 710 fork=1to4:r$(k)=rs$(k):s$(k)=ss$(k):rh(k)=rs(k):vh(k)=vs(k):nextk
- 720 ifw=6thentr$=tr$(2):ts$=ts$(2):tr=tr(2):tv=tv(2):goto760
- 722 gosub1005:rem ** deal turn-up **
- 725 ifde(i)>39then745
- 730 ifde(i)>26then750
- 735 ifde(i)>13then755
- 740 r=de(i):ts$="[211]":goto757
- 745 r=de(i)-39:ts$="[193]":goto757
- 750 r=de(i)-26:ts$="[216]":goto757
- 755 r=de(i)-13:ts$="[218]"
- 757 tr$=rr$(r):tr=r(r):tv=v(r)
- 760 i=i+1:r$(5)=tr$:s$(5)=ts$:rh(5)=tr:vh(5)=tv
- 770 d=5:gosub1045:rem ** sort hand of 5 **
- 775 sw=0:gosub2000:rem ** score hand **
- 780 gosub2310:rem ** score flush in hand **
- 782 c$="[157]":print"[147]"tab(15)" hand #";w;c$;" [146]"
- 785 cc=0:forl=1to5:r$=r$(l):s$=s$(l):r=rh(l)
- 788 c$="":ifr$="10"thenc$="[157]"
- 790 gosub1215:rem ** graphics **
- 795 onrgosub1300,1350,1400,1450,1500,1550,1600,1650,1700,1750,1800,1850,1900
- 796 ifs$="[211]"ors$="[218]"thenprint"";:goto798
- 797 print"[144]";
- 798 tb=cc*6+3:poke54276,129:forj=1to11:printtab(tb);a$(j):nextj:poke54276,128
- 800 cc=cc+1:print"[145][145][145][145][145][145][145][145][145][145][145][145]":nextl:print"";
- 802 print""
- 804 printtab(10)"turn-up is: ";:tc$="[144]":ifts$="[218]"orts$="[211]"thentc$=""
- 805 printtc$+tr$+ts$+""
- 806 printtab(10)"points in hand: ";tp
- 808 printtab(10)"game points: [151]";gt
- 815 printtab(4)"[218] hit <return>[146] to score crib [218]";
- 817 geta$:ifa$=""then817
- 820 ifa$<>chr$(13)then817
- 825 rem ** move crib var.to hand **
- 830 forx=1to4:r$(x)=rc$(x):s$(x)=sc$(x):rh(x)=rc(x):vh(x)=vc(x):nextx
- 832 r$(5)=tr$:s$(5)=ts$:rh(5)=tr:vh(5)=tv
- 835 d=5:gosub1045:rem ** sort crib of 5 **
- 836 sw=1:gosub2000:rem ** score crib **
- 837 gosub2400:rem ** score flush **
- 838 c$="[157]":print"[147]"tab(15)" crib #";w;c$;" [146]"
- 840 cc=0:tb=0:forl=1to5
- 845 r$=r$(l):s$=s$(l):r=rh(l):c$="":ifr$="10"thenc$="[157]"
- 850 gosub1215:rem ** graphics **
- 852 onrgosub1300,1350,1400,1450,1500,1550,1600,1650,1700,1750,1800,1850,1900
- 853 ifs$="[211]"ors$="[218]"thenprint"";:goto856
- 854 print"[144]";
- 856 tb=cc*6+3:poke54276,129:forj=1to11:printtab(tb);a$(j):nextj:poke54276,128
- 858 cc=cc+1:print"[145][145][145][145][145][145][145][145][145][145][145][145]":nextl:print"";
- 861 printtab(10)"turn-up is: ";tc$+tr$+ts$+""
- 862 printtab(10)"points in crib: ";tp
- 863 printtab(10)"game points: [151]";gt
- 864 print" [218] hit <return>[146] to deal another hand [218]";
- 865 geta$:ifa$=""then865
- 867 ifa$<>chr$(13)then865
- 870 rem ** store turn-up in hold **
- 880 tr$(s)=tr$:ts$(s)=ts$:tr(s)=tr:tv(s)=tv:s=s+1
- 890 nextw
- 900 rem *** last hand ***
- 905 forx=2to5:r$(x-1)=tr$(x):s$(x-1)=ts$(x):rh(x-1)=tr(x):vh(x-1)=tv(x):nextx
- 910 r$(5)="":s$(5)="":rh(5)=15:vh(5)=15
- 920 d=4:gosub1045:rem ** sort last hand **
- 930 print"[147]"
- 935 gosub2000:rem ** score hand of 4 **
- 937 gosub2310:rem ** score flush **
- 939 print"[147]"tab(14)" last hand [146]"
- 940 cc=0:forl=1to4
- 945 r$=r$(l):s$=s$(l):r=rh(l):c$="":ifr$="10"thenc$="[157]"
- 950 gosub1215:rem ** graphics **
- 955 onrgosub1300,1350,1400,1450,1500,1550,1600,1650,1700,1750,1800,1850,1900
- 957 ifs$="[211]"ors$="[218]"thenprint"";:goto960
- 958 print"[144]";
- 960 tb=cc*6+6:poke54276,129:forj=1to11:printtab(tb);a$(j):nextj:poke54276,128
- 962 cc=cc+1:print"[145][145][145][145][145][145][145][145][145][145][145][145]":nextl
- 965 printtab(13)"last hand:";tp
- 966 printtab(11)"game points:[151]";gt
- 968 print" [218] hit <return>[146] to view game totals [218]";
- 970 geta$:ifa$=""then970
- 971 ifa$<>chr$(13)then970
- 972 ifgt>ghthengh=gt
- 973 gc=gc+1:ga=ga+gt
- 980 print"[147][154]"tab(7)"[213][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][201]"
- 981 printtab(7)"[194] cribbage solitaire[154] [221]"
- 982 printtab(7)"[194] statistical averages[154] [221]"
- 984 printtab(7)"[202][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][192][203] "
- 985 printtab(9)"game points : ";gt
- 986 printtab(9)"last avg/hand: ";fnb(hl/6):iffnb(hl/6)>hhthenhh=fnb(hl/6)
- 987 printtab(9)"last avg/crib: ";fnb(cl/6):iffnb(cl/6)>hcthenhc=fnb(cl/6)
- 988 printtab(9)"average/game : ";fnb(ga/gc)
- 989 printtab(9)"average/hand : ";fnb(ha/6/gc)
- 990 printtab(9)"average/crib : ";fnb(ca/6/gc)
- 991 printtab(9)"high avg/hand: ";hh:iffnb(hl/6)<lhthenlh=fnb(hl/6)
- 992 printtab(9)"high avg/crib: ";hc:iffnb(cl/6)<lcthenlc=fnb(cl/6)
- 993 printtab(9)"low avg/hand : ";lh
- 994 printtab(9)"low avg/crib : ";lc
- 995 printtab(9)"games played : "gc:printtab(9)"game high : [151]"gh
- 996 print:print" do you want to print your results?"
- 997 geta$:ifa$<>"y"anda$<>"n"then997
- 998 ifa$="y"thengosub2800:goto63000
- 999 goto63000
- 1000 goto160
- 1005 v=int((53-i)*rnd(0)+1)
- 1010 de(i)=a(v):cd=cd+1
- 1020 forj=vto(52-i):a(j)=a(j+1):nextj
- 1030 return
- 1040 rem *** sort subroutine ***
- 1045 form=1tod-1
- 1050 forn=1tod-1
- 1055 ifrh(n)<rh(n+1)then1065
- 1060 nextn:nextm:return
- 1065 r=rh(n):rh(n)=rh(n+1):rh(n+1)=r
- 1070 r$=r$(n):r$(n)=r$(n+1):r$(n+1)=r$
- 1075 s$=s$(n):s$(n)=s$(n+1):s$(n+1)=s$
- 1080 v=vh(n):vh(n)=vh(n+1):vh(n+1)=v
- 1085 goto1060
- 1200 rem ** graphics build area **
- 1215 a$(1)="[207][183][183][183][183][183][183][183][208]"
- 1220 a$(2)="[165]"+r$+" "+c$+" [167]"
- 1225 ifr(l)=11orr(l)=12orr(l)=13then1240
- 1230 a$(3)="[165]"+s$+" [167]"
- 1235 a$(9)="[165] "+s$+"[167]"
- 1240 a$(10)="[165] "+c$+r$+"[167]"
- 1245 a$(11)="[204][175][175][175][175][175][175][175][186]"
- 1250 return
- 1300 a$(4)="[165] [167]"
- 1305 a$(5)="[165] [167]"
- 1310 a$(6)="[165] "+s$+" [167]"
- 1315 a$(7)="[165] [167]"
- 1320 a$(8)="[165] [167]"
- 1325 return
- 1350 a$(4)="[165] "+s$+" [167]"
- 1355 a$(5)="[165] [167]"
- 1360 a$(6)="[165] [167]"
- 1365 a$(7)="[165] [167]"
- 1370 a$(8)="[165] "+s$+" [167]"
- 1375 return
- 1400 a$(4)="[165] "+s$+" [167]"
- 1405 a$(5)="[165] [167]"
- 1410 a$(6)="[165] "+s$+" [167]"
- 1415 a$(7)="[165] [167]"
- 1420 a$(8)="[165] "+s$+" [167]"
- 1425 return
- 1450 a$(4)="[165] "+s$+" "+s$+" [167]"
- 1455 a$(5)="[165] [167]"
- 1460 a$(6)="[165] [167]"
- 1465 a$(7)="[165] [167]"
- 1470 a$(8)="[165] "+s$+" "+s$+" [167]"
- 1475 return
- 1500 a$(4)="[165] "+s$+" "+s$+" [167]"
- 1505 a$(5)="[165] [167]"
- 1510 a$(6)="[165] "+s$+" [167]"
- 1515 a$(7)="[165] [167]"
- 1520 a$(8)="[165] "+s$+" "+s$+" [167]"
- 1525 return
- 1550 a$(4)="[165] "+s$+" "+s$+" [167]"
- 1555 a$(5)="[165] [167]"
- 1560 a$(6)="[165] "+s$+" "+s$+" [167]"
- 1565 a$(7)="[165] [167]"
- 1570 a$(8)="[165] "+s$+" "+s$+" [167]"
- 1575 return
- 1600 a$(4)="[165] "+s$+" "+s$+" [167]"
- 1605 a$(5)="[165] "+s$+" [167]"
- 1610 a$(6)="[165] "+s$+" "+s$+" [167]"
- 1615 a$(7)="[165] [167]"
- 1620 a$(8)="[165] "+s$+" "+s$+" [167]"
- 1625 return
- 1650 a$(4)="[165] "+s$+" "+s$+" [167]"
- 1655 a$(5)="[165] "+s$+" [167]"
- 1660 a$(6)="[165] "+s$+" "+s$+" [167]"
- 1665 a$(7)="[165] "+s$+" [167]"
- 1670 a$(8)="[165] "+s$+" "+s$+" [167]"
- 1675 return
- 1700 a$(4)="[165] "+s$+" "+s$+" [167]"
- 1705 a$(5)="[165] "+s$+" "+s$+" [167]"
- 1710 a$(6)="[165] "+s$+" [167]"
- 1715 a$(7)="[165] "+s$+" "+s$+" [167]"
- 1720 a$(8)="[165] "+s$+" "+s$+" [167]"
- 1725 return
- 1750 a$(4)="[165] "+s$+" "+s$+" [167]"
- 1755 a$(5)="[165] "+s$+" "+s$+" [167]"
- 1760 a$(6)="[165] "+s$+" "+s$+" [167]"
- 1765 a$(7)="[165] "+s$+" "+s$+" [167]"
- 1770 a$(8)="[165] "+s$+" "+s$+" [167]"
- 1775 return
- 1800 a$(3)="[165]"+s$+"[146][166][166] [215][180][187][146][167]"
- 1805 a$(4)="[165] [146][166][220] [213] [161][146][167]"
- 1810 a$(5)="[165] [146]"+s$+" [207][223][161][146][167]"
- 1815 a$(6)="[165][172][146][192][192][192][192][192][190][146][167]"
- 1820 a$(7)="[165][161][223][146][186] "+s$+" [146][167]"
- 1825 a$(8)="[165][161] [146][203] [168][166] [146][167]"
- 1830 a$(9)="[165][188][170][146][215] [166][166]"+s$+"[146][167]"
- 1835 return
- 1850 a$(3)="[165]"+s$+"[146][166][166] [215][180] [146][167]"
- 1855 a$(4)="[165] [146][166][220] [202] [146][167]"
- 1860 a$(5)="[165] [146]"+s$+" [207][223][187][146][167]"
- 1865 a$(6)="[165][172][146][192][192][192][192][192][190][146][167]"
- 1870 a$(7)="[165][188][223][146][186] "+s$+" [146][167]"
- 1875 a$(8)="[165] [146][201] [168][166] [146][167]"
- 1880 a$(9)="[165] [167][146][215] [166][166]"+s$+"[146][167]"
- 1885 return
- 1900 a$(3)="[165]"+s$+"[170][146][215] [166][166] [146][167]"
- 1905 a$(4)="[165][161] [146][201] [207][166] [146][167]"
- 1910 a$(5)="[165][161][169][208] "+s$+" [146][167]"
- 1915 a$(6)="[165][188][146][192][192][192][192][192][187][146][167]"
- 1920 a$(7)="[165] [146]"+s$+" [204][169][161][146][167]"
- 1925 a$(8)="[165] [146][166][186] [202] [161][146][167]"
- 1930 a$(9)="[165] [146][166][166] [215][180]"+s$+"[146][167]"
- 1935 return
- 1995 rem *** scoring ***
- 1996 rem
- 1997 rem ** 15 comb. **
- 2000 p1=0:p2=0:p3=0:p4=0:p5=0:p6=0:tp=0:k=1
- 2010 forx=k+1to5
- 2015 ifvh(k)+vh(x)=15thenp1=p1+2
- 2020 nextx
- 2025 ifk=4then2035
- 2030 k=k+1:goto2010
- 2035 forx=3to5
- 2040 ifvh(1)+vh(2)+vh(x)=15thenp1=p1+2
- 2045 nextx
- 2050 forx=4to5
- 2055 ifvh(1)+vh(3)+vh(x)=15thenp1=p1+2
- 2060 ifvh(2)+vh(3)+vh(x)=15thenp1=p1+2
- 2065 ifvh(1)+vh(2)+vh(3)+vh(x)=15thenp1=p1+2
- 2070 nextx
- 2075 forx=1to3
- 2080 ifvh(x)+vh(4)+vh(5)=15thenp1=p1+2
- 2082 nextx
- 2085 forx=2to3
- 2086 ifvh(1)+vh(x)+vh(4)+vh(5)=15thenp1=p1+2
- 2087 nextx
- 2090 ifvh(2)+vh(3)+vh(4)+vh(5)=15thenp1=p1+2
- 2095 ifvh(1)+vh(2)+vh(3)+vh(4)+vh(5)=15thenp1=p1+2
- 2097 rem * pairs scoring *
- 2100 k=1
- 2105 forx=k+1to5
- 2110 ifrh(k)=rh(x)thenp2=p2+2
- 2115 nextx
- 2120 ifk=4then2135
- 2125 k=k+1:goto2105
- 2130 rem * seq. scoring *
- 2135 forx=1to6:sq(x)=20:nextx
- 2140 x=1:k=1:sq(x)=rh(k):x=x+1
- 2145 fork=kto4
- 2150 ifrh(k)<>rh(k+1)thensq(x)=rh(k+1):x=x+1
- 2155 nextk
- 2160 forx=1to5:hq(x)=15:nextx:k=1:x=1
- 2165 ifsq(k)=20then2268
- 2170 ifsq(k)=sq(k+1)+1then2180
- 2175 k=k+1:goto2165
- 2180 ifsq(k)=sq(k+2)+2thenp3=p3+3:forx=1to3:hq(x)=sq(k+x-1):nextx:goto2190
- 2185 k=k+1:goto2165
- 2190 ifsq(k)=sq(k+3)+3thenp3=p3+1:hq(x)=sq(k+3):goto2200
- 2195 goto2205
- 2200 ifsq(k)=sq(k+4)+4thenp3=p3+1
- 2205 x=1:z=0:pr=0
- 2210 fory=1to4
- 2215 fork=xto5
- 2220 ifhq(x)=rh(k)thenz=z+1
- 2225 nextk
- 2230 ifz=2thenpr=pr+1
- 2235 ifz=3thenpr=pr+3
- 2240 x=x+1:z=0
- 2245 nexty
- 2250 ifpr=1thenp3=p3*2
- 2255 ifpr=2thenp3=p3*4
- 2260 ifpr=3thenp3=p3*3
- 2265 rem * nibs scoring *
- 2268 ifw=7then2303
- 2270 forx=1tod
- 2275 ifrh(x)=11then2285
- 2280 goto2290
- 2285 ifs$(x)=ts$thenp4=p4+1
- 2290 nextx
- 2295 rem * jack scoring *
- 2296 iftr=11thenp4=0
- 2297 ifsw=1then2303
- 2300 iftr=11thenp5=2
- 2303 return
- 2305 rem * flush scoring *
- 2310 k=1:forx=1to5:h$(x)=str$(x):nextx
- 2315 forx=1to5
- 2320 ifs$(x)=ts$then2330
- 2325 h$(k)=s$(x):k=k+1
- 2330 nextx
- 2335 z=1:ifk=1thenp6=5
- 2340 fork=1to3
- 2345 ifh$(k)=h$(k+1)thenz=z+1
- 2350 nextk
- 2355 ifz=4thenp6=4:goto2365
- 2360 goto2370
- 2365 ifh$(k)=ts$thenp6=5
- 2370 tp=p1+p2+p3+p4+p5+p6
- 2375 gt=gt+tp:ha=ha+tp:hl=hl+tp
- 2380 return
- 2400 rem * crib flush scoring *
- 2405 z=1
- 2410 forx=1to4
- 2415 ifs$(x)=s$(x+1)thenz=z+1
- 2420 nextx
- 2425 ifz=5thenp6=5
- 2430 tp=p1+p2+p3+p4+p5+p6
- 2435 ifw<7thengt=gt+tp:ca=ca+tp:cl=cl+tp
- 2440 return
- 2600 print"[147]object of the game is to score as many"
- 2602 print"points as possible using the entire deck";
- 2604 print"of cards. multiple games can be played"
- 2606 print"in which the computer maintains the game";
- 2608 print"averages, no. of games played, game"
- 2610 print"high, etc."
- 2620 print"points are scored in the following ways:";
- 2622 print" * each 15 combination 2 pts. [146]"
- 2624 print" * each pair 2 pts. [146]"
- 2626 print" * each run (3 or more) 1 pt./card [146]"
- 2628 print" * jack as turn-up card 2 pts. [146]"
- 2630 print" * turn-up suit matches [146]"
- 2632 print" jack in hand 1 pt. [146]"
- 2634 print" * flush of 4 or 5 1 pt./card [146]"
- 2640 print"special notes:"
- 2642 print" [218] face cards hold a value of 10 when"
- 2644 print" scoring 15 combinations"
- 2646 print" [218] rank (low to high) is a,2,3...10,j,"
- 2648 print" q,k in runs of 3 or more."
- 2650 print" [218] flush in hand may be 4 or 5 cards,"
- 2652 print" but crib must be 5 to be scored."
- 2654 print" hit <return>[146] for next page";
- 2656 geta$:ifa$=""then2656
- 2658 ifa$<>chr$(13)then2656
- 2660 print"[147]the points are calculated automatically"
- 2662 print"for you in this game. therefore,"
- 2664 print"experience will teach you to understand"
- 2666 print"how the points are counted."
- 2670 print"you must select 2 cards for a second"
- 2672 print"hand called a crib (hence the name"
- 2674 print"cribbage). you will be able to score"
- 2676 print"these cards later just as you do in a"
- 2678 print"hand. to select, use the reference no."
- 2680 print"that pertains to the desired card. after";
- 2682 print"selection is made, a turn-up card is"
- 2684 print"dealt. it is to be used in scoring both"
- 2686 print"the hand and crib."
- 2690 print"six rounds including last 4 cards are"
- 2692 print"played to complete one game. a total of"
- 2694 print"121 pt. is a winning score."
- 2696 print"[218] hint: the 2nd round turn-up card"
- 2698 print"appears again in the 6th round."
- 2700 print" hit <return>[146] to play game";
- 2705 geta$:ifa$=""then2705
- 2708 ifa$<>chr$(13)then2705
- 2710 return
- 2800 open4,4:cmd4:fori=1to20:forj=1to33
- 2810 pk=peek(1023+i*40+j):ifpk<32thenpk=pk+64:goto2830
- 2820 ifpk>63thenpk=pk+32
- 2830 print#4,chr$(14)chr$(pk);:nextj:print#4:nexti
- 2840 print#4,chr$(15);chr$(12);: close4: return
- 63000 rem play again?
- 63010 print"[147]do you want to play again?"
- 63020 poke198,0:wait198,1:geta$:ifa$<>"y"anda$<>"n"then63020
- 63030 ifa$="y"then 178
- 63040 print"[147]load"chr$(34)"payload"chr$(34)",8":print"run"
- 63050 poke631,13:poke632,13:poke198,2: end
-